package com.corpgovernment.travelstandard.mapper;


import com.corpgovernment.organization.common.mybatis.TkMapper;
import com.corpgovernment.travelstandard.entity.db.TravelStandardCityConfig;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Component;

import java.util.List;

/**
 * MbSupplierProductMapper数据库操作接口类
 **/
@Component
public interface CityConfigMapper extends TkMapper<TravelStandardCityConfig> {

    List<TravelStandardCityConfig> list(TravelStandardCityConfig model);

    List<TravelStandardCityConfig> listByOrgId(@Param("orgId") String orgId, @Param("hotelType") String hotelType);

    List<TravelStandardCityConfig> listByOrgIdAreaId(@Param("id") Long id, @Param("orgId") String orgId);

    int countByCityCode(String cityCode);

    int updateAreaIdByAreaId(@Param("areaId") Long areaId, @Param("oriAreaId") Long oriAreaId);

    int updateByCityCodeAndOrgId(@Param("cityCode") String cityCode, @Param("areaId") Long areaId, @Param("orgId") String orgId, @Param("hotelType") String hotelType);

    int updateByCountryCodeAndOrgId(@Param("countryCode") String countryCode, @Param("areaId") Long areaId, @Param("orgId") String orgId, @Param("hotelType") String hotelType);

    int updateAreaIdById(@Param("id") Long id, @Param("areaId") Long areaId);
}
